<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8">
    <title>确认下单</title>
    <meta name="viewport" content="width=device-width, initial-scale=1,maximum-scale=1,user-scalable=no">
    <meta name="apple-mobile-web-app-capable" content="yes">
    <meta name="apple-mobile-web-app-status-bar-style" content="black">
    <script type="text/javascript" src="__PUBLIC__/js/jquery-3.2.1.min.js"></script>
    <script src="__PUBLIC__/js/layer/layer.js"></script>
    <!--标准mui.css-->
    <link rel="stylesheet" href="__PUBLIC__/css/mui.min.css">
    <!--App自定义的css-->
    <link rel="stylesheet" type="text/css" href="__PUBLIC__/css/app.css" />
    <script src=""></script>
</head>
<body>
<header class="mui-bar mui-bar-nav">
    <a onclick="location.href='{:U(\'order/index\')}'" class="mui-action-back mui-icon mui-icon-left-nav mui-pull-left"></a>
<!--
    <a href="{:U('order/index')}" style='position:absolute; z-index:3; width:40px; height:40px; left:0px; top:0px;background: blue;opacity:0'></a>
-->
    <h1 class="mui-title">确认下单</h1>

</header>
<div class="mui-content">

    <div class="mui-jf">
        <p id="jine">{$data[Price] * $data[Area] * $data[Times]}元</p>
        <p>请您在<i class="clf6"></i>时间内尽快完成支付</p>
    </div>
    <div class="mui-jfinfo">费用明细</div>
    <ul class="mui-table-view cl6">
        <li class="mui-table-view-cell">
            <a class="fl">仓库租赁费用</a> <span id="cangkufeiyong" class="fr">{$data[Price] * $data[Area] * $data[Times]}元</span></li>
        <li class="mui-table-view-cell">
            <a class="fl">单价</a> <span class="fr">{$data[Price]}元</span></li>
        <li class="mui-table-view-cell">
            <a class="fl">租用面积</a> <span class="fr">{$data.Area}</span></li>
        <li class="mui-table-view-cell">
            <a class="fl">租期</a> <span class="fr">{$data.Times}</span></li>
        <li class="mui-table-view-cell">
            <a class="fl">租赁费折扣</a> <span class="fr">{$data.DisWH}%</span></li><!--暂未处理-->
        <li class="mui-table-view-cell">
            <a class="fl">上门提货运费</a> <span class="fr">{$data.FeePick}元</span></li>
        <li class="mui-table-view-cell">
            <a class="fl">上门送货运费</a> <span class="fr">{$data.FeeDelive}元</span></li>
        <li class="mui-table-view-cell">
            <a class="fl">运费折扣</a> <span class="fr">{$data.DisLOG}%</span></li>
        <li class="mui-table-view-cell">
            <a class="fl">保险费</a> <span class="fr">{$data.FeeIns}元</span></li>
        <li class="mui-table-view-cell">
            <a class="fl">包装费用</a> <span class="fr">0元</span></li>
        <li class="mui-table-view-cell">
            <a class="fl">附加费</a> <span class="fr">0元</span></li>
        <li class="mui-table-view-cell">
            <a class="mui-navigate-right">优惠券
                <span class="mui-pull-right mr20" id="tan">
                    <i class="mui-pull-right"></i><span id="mingxi">请选择优惠券</span>
                </span>

            </a>
        </li>
    </ul>
    <div class="mui-jfinfo">选择支付方式</div>
    <form class="mui-input-group">
       <!-- <div class="mui-input-row mui-checkbox mui-radio h50">
            <label class="texl"><img class="mui-media-object w3h3 mui-pull-left" src="__PUBLIC__/images/bizimg/yezf.png"><em>余额支付</em></label>
            <input name="radio1" class="t10" type="radio" checked>
        </div>
        <div class="mui-input-row mui-checkbox mui-radio h50">
            <label class="texl"><img class="mui-media-object w3h3 mui-pull-left" src="__PUBLIC__/images/bizimg/apple.png"><em>Apple Pay</em></label>
            <input name="radio1" class="t10" type="radio" checked>
        </div>-->
        <div class="mui-input-row mui-checkbox mui-radio h50">
            <label class="texl"><img class="mui-media-object mui-pull-left" src="__PUBLIC__/images/bizimg/wxzf.png"><em>微信支付</em></label>
            <input name="radio1" class="t10" type="radio" checked>
        </div>

       <!-- <div class="mui-input-row mui-checkbox mui-radio h50">
            <label class="texl"><img class="mui-media-object mui-pull-left" src="__PUBLIC__/images/bizimg/zfbzf.png"><em>支付宝支付</em></label>
            <input name="radio1" class="t10" type="radio" checked>
        </div>

        <div class="mui-input-row mui-checkbox mui-radio h50">
            <label class="texl"><img class="mui-media-object w3h3 mui-pull-left" src="__PUBLIC__/images/bizimg/ylzf.png"><em>银联支付</em></label>
            <input name="radio1" class="t10" type="radio" checked>
        </div>-->
    </form>
    <button type="button" class=" mui-btn-sz mb20">确认支付<i id="zhifu">{$data[Price] * $data[Area] * $data[Times]}</i>元</button>
</div>
</body>

</html>
<script>
    $(function(){
        var  positive = 1;
        var decimal = 0;
        var num = positive + "." + decimal;
        $(".clf6").html(num);
        var clock=setInterval(function(){
            if(decimal != 0){
                decimal = decimal - 1;
                num = toDouble(positive) + "." + toDouble(decimal);
                $(".clf6").html(num);
            }else if(decimal == 0 && positive!=0){
                decimal = 59;
                positive = positive - 1;
                num = toDouble(positive) + "." + toDouble(decimal);
                $(".clf6").html(num);
            }else if(decimal == 0 && positive == 0){
                num = 0;
                $(".clf6").html(num);
                clearInterval(clock)
                alert("倒计时截止！")
            }
            $(".clf6").html(num);
        },1000);

        function toDouble(num){    //把一位数字前面加0
            if(num<10){
                return "0"+num;
            }else if(num > 9){
                return num;
            }
        }
    })
</script>
<script>
    $('#tan').click(function () {
        layer.open({
            type: 2,
            title: '选择优惠卷',
            shadeClose: true,
            shade: 0.8,
            area: ['380px', '90%'],
            content: "{:U('selectTheCoupon')}&id="+getQueryString('id') //iframe的url
        });
    })
    function getQueryString(name) {
        var reg = new RegExp("(^|&)" + name + "=([^&]*)(&|$)", "i");
        var r = window.location.search.substr(1).match(reg);
        if (r != null) return unescape(r[2]); return null;
    }
    //alert(getQueryString('id'))
</script>